package com.thib.models;

import java.text.SimpleDateFormat;
import java.util.Date;

public class Finished {
	
	private String channel;
	private String chicon;
	private String config_name;
	private String title;
	private String subtitle;
	private String description;
	private String episode;
	private int id;
	private int start;
	private int end;
	private int duration;
	private String creator;
	private String pri;
	private String status;
	private String schedstate;
	private String filesize;
	private String url;
	private int channelid;
	private int contenttype;
	public Finished(){
		
		super();
		this.channel 		= "";
		this.chicon 		= "";
		this.config_name 	= "";
		this.title 			= "";
		this.description	= "";
		this.id 			= -42;
		this.start 			= -42;
		this.end 			= -42;
		this.duration 		= -42;
		this.creator 		= "";
		this.pri 			= "";
		this.status 		= "";
		this.schedstate 	= "";
		this.filesize 		= "";
		this.url 			= "";
		this.channelid 		= -42;
		this.contenttype	= -42;
	}
	
	public Finished(String channel,	 String chicon,	String config_name, String title, String subtitle,String description,String episode, int id, 
			int start, int end, int duration, String creator, String pri, String status,
			String schedstate, String filesize, String url, int channelid, int contenttype ){
		
		super();
		this.channel 		= channel;
		this.chicon 		= chicon;
		this.config_name	= config_name;
		this.title 			= title;
		this.description	= description;
		this.id 			= id;
		this.start 			= start;
		this.end 			= end;
		this.duration 		= duration;
		this.creator 		= creator;
		this.pri 			= pri;
		this.status 		= status;
		this.schedstate 	= schedstate;
		this.filesize 		= filesize;
		this.url 			= url;
		this.channelid 		= channelid;
		this.contenttype 	= contenttype;
		this.subtitle 		= subtitle;
		this.episode = episode;
	}
	
	public String getDurationOnhours(){
		
		int hours 		=  duration / 3600;
		int minutes 	=  (duration % 3600)/60;
		return hours+":"+minutes;
	}
	
	public Date StampToDate(int i)
	{
		Date date = new Date(i);
		return date;
	}
	
	public String 	getChannel() 		{return this.channel;};
	public String 	getChicon()  		{return this.chicon;};
	public String 	getConfig_name() 	{return this.config_name;};
	public String 	getTitle()  		{return this.title;};
	public String 	getSubtitle()  		{return this.subtitle;};
	public String 	getDescription() 	{return this.description;};
	public String 	getEpisode() 		{return this.episode;};
	public int 		getId()  			{return this.id;};
	public int 		getStart()  		{return this.start;};
	public int 		getEnd()  			{return this.end;};
	public int	 	getDuration()  		{return this.duration;};
	public String 	getCreator()  		{return this.creator;};
	public String 	getPri()  			{return this.pri;};
	public String 	getStatus()  		{return this.status;};
	public String 	getSchedstate()  	{return this.schedstate;};
	public String 	getFilesize()  		{return this.filesize;};
	public String 	getUrl()  			{return this.url;}; 
	public int 		getChannelid() 		{return this.channelid;}
	public int 		getContenttype() 	{return this.contenttype;}
	
	public void setChannel(String channel) 			{ this.channel = channel;};
	public void setChicon(String chicon)  			{ this.chicon = chicon;};
	public void setConfig_name(String config_name)  { this.config_name = config_name;};
	public void setTitle(String title)  			{ this.title = title;};
	public void setSubtitle(String subtitle)  		{ this.subtitle = subtitle;};
	public void setDescription(String description) 	{ this.description = description;};
	public void setEpisode(String episode) 	{ this.episode = episode;};
	public void setId(int id)  						{ this.id = id;};
	public void setStart(int start)  				{ this.start = start;};
	public void setEnd(int end)  					{ this.end = end;};
	public void setDuration(int duration)  			{ this.duration = duration;};
	public void setCreator(String creator)  		{ this.creator = creator;};
	public void setPri(String pri)  				{ this.pri = pri;};
	public void setStatus(String status)  			{ this.status = status;};
	public void setSchedstate(String schedstate)  	{ this.schedstate = schedstate;};
	public void setFilesize(String filesize)  		{ this.filesize = filesize;};
	public void setUrl(String url)  				{ this.url = url;};
	public void setChannelid(int channelid)			{this.channelid = channelid;}
	public void setContenttype(int contenttype)		{this.contenttype = contenttype;}
}
